<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>分批次</title>
</head>

<body>
<script type="text/javascript">
	function rec(form){
		var a=form.fengshu.value;
		a=parseInt(a/10)
		switch(a){
			case 9:{
			document.write("优秀");
			break;}
			case 8:
			      {
				document.write("良好");
			break;}
			case 7:{
			document.write("中等");
			break;}
			case 6:{
				document.write("及格");
				break;}
				
			default:
			{
				document.write("不及格");
			}
		}
	}
</script>
<form action="">
<input type="text" name="fengshu" value="" />
<input type="button" name="button" value="确定" onclick="rec(this.form)" />
</form>
</body>
</html>
